package bean;

import java.io.Serializable;
import java.util.Objects;

public class Tail implements Serializable {
    private String username;
    private String password;
    private String phone;
    private String address;

    public Tail(){}

    public Tail(String username, String password, String phone, String address) {
        this.username = username;
        this.password = password;
        this.phone = phone;
        this.address = address;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Tail tail = (Tail) o;
        return Objects.equals(username, tail.username) && Objects.equals(password, tail.password) && Objects.equals(phone, tail.phone) && Objects.equals(address, tail.address);
    }

    @Override
    public int hashCode() {
        return Objects.hash(username, password, phone, address);
    }

    @Override
    public String toString() {
        return "Tail{" +
                "username='" + username + '\'' +
                ", password='" + password + '\'' +
                ", phone='" + phone + '\'' +
                ", address='" + address + '\'' +
                '}';
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }
}
